Matthias Clasen [Sat, 9 May 2020 21:31:18 +0000 (17:31 -0400)]
testsuite: Clean up unexpected children
If you call gtk_widget_set_parent on an unsuspecting
parent widget, it is your reponsibility to clean up
before the parent gets finalized.
Matthias Clasen [Sat, 9 May 2020 19:20:15 +0000 (15:20 -0400)]
popover: Fix a reference leak
Don't leak the reference to the default widget.
Matthias Clasen [Sat, 9 May 2020 19:19:39 +0000 (15:19 -0400)]
filechooserdialog: Fix disposing
We need to drop our widgetry in dispose to prevent
leakage.
Matthias Clasen [Sat, 9 May 2020 18:14:55 +0000 (14:14 -0400)]
colorchooserdialog: Fix disposing
We need to drop our widgetry in dispose to prevent
leakage.
Matthias Clasen [Sat, 9 May 2020 18:10:38 +0000 (14:10 -0400)]
fontchooserdialog: Fix disposing
We need to drop our widgetry in dispose to prevent
leakage.
Matthias Clasen [Sat, 9 May 2020 16:09:13 +0000 (12:09 -0400)]
Drop gtk_widget_destroyed
Use g_object_add_weak_pointer or a weak reference instead.
Matthias Clasen [Sat, 9 May 2020 16:03:11 +0000 (12:03 -0400)]
Stop using gtk_widget_destroyed
Replace all internal use of gtk_widget_destroyed
by g_object_add_weak_pointer.
Matthias Clasen [Mon, 11 May 2020 15:52:24 +0000 (15:52 +0000)]
Merge branch 'wip/exalm/test' into 'master'
Fix (most of the) tests
See merge request GNOME/gtk!1873
Matthias Clasen [Mon, 11 May 2020 15:23:40 +0000 (15:23 +0000)]
Merge branch 'teardown-cleanup-2' into 'master'
Treeview teardown cleanup
See merge request GNOME/gtk!1872
Alexander Mikhaylenko [Mon, 11 May 2020 14:57:25 +0000 (19:57 +0500)]
tests: Stop explicitly showing widgets
Alexander Mikhaylenko [Mon, 11 May 2020 15:03:51 +0000 (20:03 +0500)]
tests: Remove redundant image from testdialog
Alexander Mikhaylenko [Mon, 11 May 2020 14:54:32 +0000 (19:54 +0500)]
tests: Connect signal properly for testvolumebutton
Alexander Mikhaylenko [Mon, 11 May 2020 14:53:31 +0000 (19:53 +0500)]
tests: Remove orientation from testvolumebutton
GtkVolumeButton isn't orientable anymore.
Alexander Mikhaylenko [Mon, 11 May 2020 14:51:18 +0000 (19:51 +0500)]
test: Stop using stock-size for teestverticalcells
Alexander Mikhaylenko [Mon, 11 May 2020 14:47:58 +0000 (19:47 +0500)]
tests: Fix testtreeelistmodel
Stop using GtkContainer API for GtkListBoxRow and GtkToggleButton.
Alexander Mikhaylenko [Mon, 11 May 2020 14:32:52 +0000 (19:32 +0500)]
tests: Fix teststackedheader
Connect to signals programmatically.
Matthias Clasen [Sun, 10 May 2020 21:54:49 +0000 (17:54 -0400)]
testsuite: Enable the remaining template tests
These are no longer failing.
Matthias Clasen [Mon, 11 May 2020 14:00:12 +0000 (10:00 -0400)]
treeview: Break reference cycles on unroot
It is a bad idea to have such cycles in the first place,
and there is no need to let them linger past unroot.
This stop the treeview depending on run_dispose to get
freed, a simple unparent will work now.
Alexander Mikhaylenko [Mon, 11 May 2020 14:27:41 +0000 (19:27 +0500)]
tests: Fix teststack "add icon" button
Matthias Clasen [Mon, 11 May 2020 14:24:45 +0000 (14:24 +0000)]
Merge branch 'wip/baedert/for-master' into 'master'
Wip/baedert/for master
See merge request GNOME/gtk!1867
Alexander Mikhaylenko [Mon, 11 May 2020 14:21:03 +0000 (19:21 +0500)]
tests: Fix testselectionmode
Stop using <packing/> and GtkContainer API for random widgets.
Yuri Chornoivan [Mon, 11 May 2020 14:20:13 +0000 (14:20 +0000)]
Update Ukrainian translation
Alexander Mikhaylenko [Mon, 11 May 2020 14:13:04 +0000 (19:13 +0500)]
tests: Fix testoverlay
Stop using child properties and margin property.
Alexander Mikhaylenko [Mon, 11 May 2020 14:08:56 +0000 (19:08 +0500)]
tests: Simplify testorientable
Since GtkButtonBox is gone, remove the separator and change grid to box.
Alexander Mikhaylenko [Mon, 11 May 2020 14:03:53 +0000 (19:03 +0500)]
tests: Remove testmodelbutton
GtkModelButton is private now, so it can't work anymore.
Alexander Mikhaylenko [Mon, 11 May 2020 13:55:15 +0000 (18:55 +0500)]
tests: Remove use-popover from testmenubutton
The corresponding property doesn't exist anymore.
Alexander Mikhaylenko [Mon, 11 May 2020 13:54:53 +0000 (18:54 +0500)]
tests: Fix testlogout
Stop using GtkApplication::quit signal.
Alexander Mikhaylenko [Mon, 11 May 2020 13:54:23 +0000 (18:54 +0500)]
tests: Fix testiconview
Stop using GtkContainer API for GtkPopover.
Alexander Mikhaylenko [Mon, 11 May 2020 13:39:32 +0000 (18:39 +0500)]
tests: Fix testheightforwidth layout
Stop using child properties and setting visible=true everywhere.
Alexander Mikhaylenko [Mon, 11 May 2020 13:31:59 +0000 (18:31 +0500)]
tests: Expand content for testheaderbar
Alexander Mikhaylenko [Mon, 11 May 2020 13:11:48 +0000 (18:11 +0500)]
tests: Fix testgtk
An assorted collection of fixes.
Matthias Clasen [Mon, 11 May 2020 12:51:08 +0000 (12:51 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
Matthiasc/for master
Closes #2729 and #2730
See merge request GNOME/gtk!1870
Matthias Clasen [Mon, 11 May 2020 04:17:53 +0000 (00:17 -0400)]
menubutton: Cosmetics
Fix a few typos in the docs.
Matthias Clasen [Mon, 11 May 2020 01:26:19 +0000 (21:26 -0400)]
Refresh the tutorial examples
Redo this series of examples from 2013, and adapt it to modern
way of doing things. The biggest differences are that we use
a headerbar right from the start, and don't mention the app
menu.
Fixes: #2730
Matthias Clasen [Mon, 11 May 2020 00:15:31 +0000 (20:15 -0400)]
applicationswindow: Make show-menubar FALSE by default
The fallback to the menubar is not a good sight,
we should not do that by default.
Matthias Clasen [Sun, 10 May 2020 22:23:32 +0000 (18:23 -0400)]
docs: Cosmetic updates to the tutorial
Since the meson conversion, we are no longer expanding
gtk-doc references in this file, so take them out. And
touch up the wording in various places.
Matthias Clasen [Sun, 10 May 2020 21:13:26 +0000 (17:13 -0400)]
Clean up a leak in a test
One of the treeview tests was calling gtk_widget_destroy
on a child instead of the toplevel, which leaks the toplevel
unnecessarily. Plus, we're moving towards allowing destroy
only on toplevels.
Matthias Clasen [Sun, 10 May 2020 18:07:17 +0000 (14:07 -0400)]
treeviewcolumn: Another case of box <> frame confusion
Don't call your boxes frames, folks!
Matthias Clasen [Sun, 10 May 2020 17:29:40 +0000 (13:29 -0400)]
builderscope: Fix finalize <> dispose confusion
Don't chain up to dispose if you implement finalize.
This fix s courtesy of GOBJECT_DEBUG=objects.
Matthias Clasen [Sun, 10 May 2020 17:18:22 +0000 (13:18 -0400)]
print dialog: Fix frame <> box confusion
It is a bad idea to have a GtkBox called frame, event
if it started out its existence as a GtkFrame.
Matthias Clasen [Sun, 10 May 2020 17:16:52 +0000 (13:16 -0400)]
treeview: Ensure search popover is properly inserted
The css tree and the widget tree are not in sync, so we need
to explicitly set the parent of the css node before inserting
the widget, or else we end up with critical warnings and a
non-working popover.
This can be seen in the print dialog, when moving the focus
to the printer list.
Matthias Clasen [Sun, 10 May 2020 16:59:27 +0000 (12:59 -0400)]
print-editor: Cosmetics
Make the about dialog a bit less barren.
Matthias Clasen [Sun, 10 May 2020 16:53:37 +0000 (12:53 -0400)]
print-editor: Fix a critical
GtkWindow is no longer a container, so don't call
gtk_container_add on it.
Matthias Clasen [Mon, 11 May 2020 11:23:15 +0000 (11:23 +0000)]
Merge branch 'focusable-property' into 'master'
Focusable property
See merge request GNOME/gtk!1834
Emmanuele Bassi [Mon, 11 May 2020 10:02:53 +0000 (10:02 +0000)]
Merge branch 'aperezdc/vk-result-range-size' into 'master'
Fix build issue due to missing VK_RESULT_RANGE_SIZE
See merge request GNOME/gtk!1871
Adrian Perez de Castro [Mon, 11 May 2020 07:07:41 +0000 (10:07 +0300)]
Fix build issue due to missing VK_RESULT_RANGE_SIZE
Conditionally check whether the Vulkan headers version defines
VK_RESULT_RANGE_SIZE, and avoid using it for version >=140. The
following comming in Vulkan-Headers has removed the enum value:
https://github.com/KhronosGroup/Vulkan-Headers/commit/
0c5351f5e9114d3e9033aeae51d036a3d201c082#diff-
4febd94c0666d59030d8b1dd20c72403
Matthias Clasen [Mon, 11 May 2020 04:29:41 +0000 (00:29 -0400)]
Clarify docs around focus.
Matthias Clasen [Mon, 11 May 2020 03:58:30 +0000 (23:58 -0400)]
Remove lots of focus vfuncs
In many cases, the default widget vfuncs work just fine,
combined with setting focusable.
Matthias Clasen [Mon, 11 May 2020 03:42:02 +0000 (23:42 -0400)]
widget: Fix gtk_widget_focus_all for !focusable
This was a case that wasn't handle properly when
the focus is entering from the outside, in forward
direction.
Matthias Clasen [Tue, 5 May 2020 18:57:21 +0000 (14:57 -0400)]
widget: Add a :focusable property
Add back a property that determines whether an individual
widget will accept focus or not. :can-focus prevents the
focus from ever entering the entire widget hierarchy
below a widget, and :focusable just determines if grabbing
the focus to the widget itself will succeed.
See #2686
Alexander Mikhaylenko [Sun, 10 May 2020 23:58:36 +0000 (04:58 +0500)]
tests: Fix testgmenu
GtkMenuButton isn't a GtkButton anymore.
Alexander Mikhaylenko [Sun, 10 May 2020 23:57:01 +0000 (04:57 +0500)]
tests: Add missing margin for testglarea
Alexander Mikhaylenko [Sun, 10 May 2020 23:55:22 +0000 (04:55 +0500)]
tests: Fix testgiconpixbuf test
Don't use GtkContainer API on GtkWindow.
Alexander Mikhaylenko [Sun, 10 May 2020 23:52:04 +0000 (04:52 +0500)]
tests: Fix testfontchooser layout
Remove an extra box so that we don't need to expand the chooser.
Alexander Mikhaylenko [Sun, 10 May 2020 23:47:26 +0000 (04:47 +0500)]
tests: Fix testfilechooser test
Don't use GtkContainer API on GtkWindow.
Alexander Mikhaylenko [Sun, 10 May 2020 22:47:39 +0000 (03:47 +0500)]
tests: Add missing margin for testentrycompletion
Alexander Mikhaylenko [Sun, 10 May 2020 22:38:10 +0000 (03:38 +0500)]
tests: Fix testdnd popup
Don't use GtkContainer API for GtkWindow.
Alexander Mikhaylenko [Sun, 10 May 2020 22:36:02 +0000 (03:36 +0500)]
tests: Fix testdialogtest
Fix deprecations in UI files, add a missing expand.
Alexander Mikhaylenko [Sun, 10 May 2020 22:22:50 +0000 (03:22 +0500)]
tests: Update testcombochange test
GtkComboBox doesn't have list mode anymore, remove that.
Alexander Mikhaylenko [Sun, 10 May 2020 22:22:34 +0000 (03:22 +0500)]
tests: Fix testcombo
Don't use GtkContainer API on GtkFrame.
Alexander Mikhaylenko [Sun, 10 May 2020 22:22:15 +0000 (03:22 +0500)]
tests: Fix testcalendar layout
Add a missing expand.
Alexander Mikhaylenko [Sun, 10 May 2020 21:49:09 +0000 (02:49 +0500)]
tests: Add missing margin to simple test
Alexander Mikhaylenko [Sun, 10 May 2020 21:46:50 +0000 (02:46 +0500)]
tests: Fix testadjustsize test
Don't assume GtkWindow is a container, also add missing expand and margin.
Alexander Mikhaylenko [Sun, 10 May 2020 21:46:28 +0000 (02:46 +0500)]
tests: Fix testappchooser test
Don't assume GtkWindow is a container.
Alexander Mikhaylenko [Sun, 10 May 2020 21:32:41 +0000 (02:32 +0500)]
tests: Fix testaccel layout
hexpand doesn't matter there, set vexpand instead.
Alexander Mikhaylenko [Sun, 10 May 2020 21:32:27 +0000 (02:32 +0500)]
tests: Fix testaccel indentation
Alexander Mikhaylenko [Sun, 10 May 2020 21:26:42 +0000 (02:26 +0500)]
tests: Fix syncscroll
Set expand for the scrolled windows.
Alexander Mikhaylenko [Sun, 10 May 2020 21:18:06 +0000 (02:18 +0500)]
tests: Fix overlayscroll
Set expand for the scrolled window.
Alexander Mikhaylenko [Sun, 10 May 2020 20:59:25 +0000 (01:59 +0500)]
tests: Fix print-editor
Don't assume GtkWindow is a container.
Matthias Clasen [Sun, 10 May 2020 15:12:07 +0000 (11:12 -0400)]
testsuite: Add more tests for automated components
Add template tests that show the complex dialogs before
destroying them. This reveals that we are leaking in
several of them. These leaks don't show up if the
dialogs are destroyed right away, as the existing
tests do.
Disable the two failing tests for now:
/template/GtkFileChooserDialog/show
/template/GtkPrintUnixDialog/show
Matthias Clasen [Sun, 10 May 2020 14:50:18 +0000 (10:50 -0400)]
testsuite: Use lowercase component in test paths
This is purely cosmetic.
Matthias Clasen [Sun, 10 May 2020 13:16:32 +0000 (09:16 -0400)]
textview: Ensure popup menu is properly inserted
In the presence of attached children, the css tree and the
widget tree are not in sync, so we need to explicitly set
the parent of the css node before inserting the widget, or
else we end up with critical warnings and a non-working
menu.
This can be seen in testtextview.
Matthias Clasen [Sun, 10 May 2020 13:14:25 +0000 (09:14 -0400)]
textview: Give attached children a different css name
If we use "text" for the children that are attached to the
text view, they end up rendering the same background as the
main text content, causing that content to be covered up.
Fixes: #2729
Aurimas Černius [Sun, 10 May 2020 19:34:16 +0000 (22:34 +0300)]
Updated Lithuanian translation
Matthias Clasen [Sun, 10 May 2020 18:15:57 +0000 (18:15 +0000)]
Merge branch 'wip/exalm/headerbar-dragging' into 'master'
Extract GtkWindow dragging and titlebar actions
Closes #2689
See merge request GNOME/gtk!1814
Yuri Chornoivan [Sun, 10 May 2020 16:03:34 +0000 (16:03 +0000)]
Update Ukrainian translation
Piotr Drąg [Sun, 10 May 2020 12:34:33 +0000 (14:34 +0200)]
Update POTFILES.in
Timm Bäder [Sun, 10 May 2020 07:20:53 +0000 (09:20 +0200)]
gl shaders: unify frag coord handling
Timm Bäder [Sun, 10 May 2020 07:07:30 +0000 (09:07 +0200)]
gl renderer: Only destroy shader programs with ids > 0
We may return -1 as an error return value.
Timm Bäder [Thu, 7 May 2020 17:00:30 +0000 (19:00 +0200)]
scrolledwindow: Always keep the main child first
Otherwise we can't pick the scrollbars, which are allocated behind it.
Timm Bäder [Thu, 7 May 2020 07:10:01 +0000 (09:10 +0200)]
stylecontext: Remove _save_named
Now unused.
Timm Bäder [Thu, 7 May 2020 07:07:43 +0000 (09:07 +0200)]
scrolledwindwo: Add a permanent junction node
Use that instead of save_named'ing a junction node.
Timm Bäder [Thu, 7 May 2020 07:01:50 +0000 (09:01 +0200)]
printunixdialog: Use two "paper" css nodes
Instead of save_named'ing to a temporary "paper" node.
Timm Bäder [Thu, 7 May 2020 06:40:09 +0000 (08:40 +0200)]
cellrenderertoggle: Replace save_named with a css node
Timm Bäder [Thu, 7 May 2020 06:20:03 +0000 (08:20 +0200)]
widget: Move {dis,}connect_frame_clock into their only caller
Makes sense to have these only in (un)realize.
Timm Bäder [Thu, 7 May 2020 06:19:52 +0000 (08:19 +0200)]
stylecontext: Remove some unused private API
Timm Bäder [Wed, 6 May 2020 17:17:11 +0000 (19:17 +0200)]
css: Make GtkStyleAnimation and subclasses non-objects
Making them GObjects is unnecessary. This enables further optimizations
down the road. The only place we use them in is gtkcssanimatedstyle.c
after all.
Timm Bäder [Wed, 6 May 2020 10:34:56 +0000 (12:34 +0200)]
testtreeview: Properly annotate a switch fallthrough
Timm Bäder [Wed, 6 May 2020 09:40:52 +0000 (11:40 +0200)]
css: Drop a few dynamic type checks
We hit these code paths a lot
Timm Bäder [Wed, 6 May 2020 09:37:51 +0000 (11:37 +0200)]
csstransiton: Save finished state
Once a transtion is finished it can't change to unfinished again, so we
don't have to consult the progress tracker all the time.
Timm Bäder [Wed, 6 May 2020 08:25:05 +0000 (10:25 +0200)]
gtkarray: memcpy() directly into the GPtrArray
Timm Bäder [Wed, 6 May 2020 08:24:15 +0000 (10:24 +0200)]
gtkarray: Create GPtrArray in insert() if we have to
Timm Bäder [Wed, 6 May 2020 08:05:11 +0000 (10:05 +0200)]
gtkarray: Fix a typo
Timm Bäder [Wed, 6 May 2020 07:56:52 +0000 (09:56 +0200)]
Make dimension values and calc values just number values
Timm Bäder [Wed, 6 May 2020 06:23:17 +0000 (08:23 +0200)]
csscalcvalue: Avoid allocating memory in compute()
We already know how many values we're going to have, it's
value->n_terms.
Christoph Reiter [Sun, 10 May 2020 06:31:37 +0000 (08:31 +0200)]
CI: install brotli in msys2
Not a direct dependency, but the freetype package is missing it atm
Matthias Clasen [Sun, 10 May 2020 00:36:49 +0000 (00:36 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
window: Remove some dead code
Closes #2726 and #2724
See merge request GNOME/gtk!1862
Matthias Clasen [Sat, 9 May 2020 23:41:30 +0000 (19:41 -0400)]
placesview: Don't do the same thing twice
When the schema is supported, we want to remove
the error style class, not add it again. Pointed
out by Rafał Mikrut.
Fixes: #2724
Matthias Clasen [Sat, 9 May 2020 23:40:06 +0000 (19:40 -0400)]
gsk: Fix a typo
We were checking x_offset twice, when we meant to check
x_offset and y_offset. Pointed out by Rafał Mikrut.
Fixes: #2726
Matthias Clasen [Sat, 9 May 2020 23:23:29 +0000 (19:23 -0400)]
Add a test for refcounts under reordering
It turns out that we have a ref leak at the very
core of our dom model :( gtk_widget_insert_before/after
leak a reference if the widget was already under
the same parent. This is something that GtkBox
frequently does. It shows up e.g. when packing
widgets at the end in a headerbar.